<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>jq sort</title>
    <script src="/jquery-3.2.1.js"></script>
    <script type="text/javascript">
        function aortNumber(a,b) {
            return a-b;
        }
        $(document).ready(function () {
            var arr = new Array(12,554,1115,222,5111,313132,12);
            arr.toString();
            arr.sort(aortNumber);
            $.unique(arr);
            $.each(arr,function (i,n) {
                document.write("arr["+i+"]的值是："+n+"<br>");
            });
        });
    </script>
</head>
<body>
<h3>sort函数的练习</h3><br />

</body>
</html>